-- CALC_HEAD_ALTAR_BONUS

-- 计算头骨祭坛的奖励
-- @param user  玩家对象
return function(user)
    local ret = {
        ["status"] = {["status"] = 111, ["prop"] = {507,1,500,4,}, ["end_round"] = 4,}, -- 诅咒
    };
    
    -- 50%概率：生命值或魔法值+10
    -- 30%概率：生命值或魔法值+20
    -- 20%概率：攻击或魔力+1

    local arr = {
        {["id"] = 1, ["attrib"] = "max_hp", ["value"] = 10, ["ratio"] = 25 }, -- 生命值
        {["id"] = 2, ["attrib"] = "max_mp", ["value"] = 10, ["ratio"] = 25 }, -- 魔法值
        {["id"] = 3, ["attrib"] = "max_hp", ["value"] = 20, ["ratio"] = 15 }, -- 生命值
        {["id"] = 4, ["attrib"] = "max_mp", ["value"] = 20, ["ratio"] = 15 }, -- 魔法值
        {["id"] = 5, ["attrib"] = "attack", ["value"] = 1,  ["ratio"] = 5 },  -- 攻击
        {["id"] = 6, ["attrib"] = "magic",  ["value"] = 1,  ["ratio"] = 5 },  -- 魔力
    };

    local seed = DungeonM.getRandSeed("CALC_HEAD_ALTAR_BONUS");
    local info = fetchElemBySeed(arr, seed);

    ret["bonus"] = {
        { 2, info["attrib"], info["value"], },
    };

    return ret;
    
end